package odv.webservice;

public class SolicitudCotizacionServerProxy implements odv.webservice.SolicitudCotizacionServer {
  private String _endpoint = null;
  private odv.webservice.SolicitudCotizacionServer solicitudCotizacionServer = null;
  
  public SolicitudCotizacionServerProxy() {
    _initSolicitudCotizacionServerProxy();
  }
  
  public SolicitudCotizacionServerProxy(String endpoint) {
    _endpoint = endpoint;
    _initSolicitudCotizacionServerProxy();
  }
  
  private void _initSolicitudCotizacionServerProxy() {
    try {
      solicitudCotizacionServer = (new odv.webservice.SolicitudCotizacionServerServiceLocator()).getSolicitudCotizacionServerPort();
      if (solicitudCotizacionServer != null) {
        if (_endpoint != null)
          ((javax.xml.rpc.Stub)solicitudCotizacionServer)._setProperty("javax.xml.rpc.service.endpoint.address", _endpoint);
        else
          _endpoint = (String)((javax.xml.rpc.Stub)solicitudCotizacionServer)._getProperty("javax.xml.rpc.service.endpoint.address");
      }
      
    }
    catch (javax.xml.rpc.ServiceException serviceException) {}
  }
  
  public String getEndpoint() {
    return _endpoint;
  }
  
  public void setEndpoint(String endpoint) {
    _endpoint = endpoint;
    if (solicitudCotizacionServer != null)
      ((javax.xml.rpc.Stub)solicitudCotizacionServer)._setProperty("javax.xml.rpc.service.endpoint.address", _endpoint);
    
  }
  
  public odv.webservice.SolicitudCotizacionServer getSolicitudCotizacionServer() {
    if (solicitudCotizacionServer == null)
      _initSolicitudCotizacionServerProxy();
    return solicitudCotizacionServer;
  }
  
  public java.lang.String cotizar(java.lang.String arg0) throws java.rmi.RemoteException{
    if (solicitudCotizacionServer == null)
      _initSolicitudCotizacionServerProxy();
    return solicitudCotizacionServer.cotizar(arg0);
  }
  
  
}